<template>
  <div class="decoration-component">
    <!-- 边框装饰 -->
    <div v-if="type.startsWith('border-')" class="border-decoration" :class="borderClass" :style="borderStyle">
      <!-- 科技感边框1 - 四角装饰 -->
      <div v-if="type === 'border-1'" class="border-corners">
        <div class="corner corner-tl"></div>
        <div class="corner corner-tr"></div>
        <div class="corner corner-bl"></div>
        <div class="corner corner-br"></div>
      </div>
      
      <!-- 科技感边框2 - 发光边框 -->
      <div v-if="type === 'border-2'" class="border-glow"></div>
      
      <!-- 科技感边框3 - 扫描线边框 -->
      <div v-if="type === 'border-3'" class="border-scan">
        <div class="scan-border-line"></div>
      </div>
      
      <!-- 科技感边框4 - 渐变边框 -->
      <div v-if="type === 'border-4'" class="border-gradient"></div>
      
      <!-- 科技感边框5 - 虚线边框 -->
      <div v-if="type === 'border-5'" class="border-dashed"></div>
      
      <!-- 科技感边框6 - 立体边框 -->
      <div v-if="type === 'border-6'" class="border-3d"></div>
      
      <!-- 科技感边框7 - 流光边框 -->
      <div v-if="type === 'border-7'" class="border-flow">
        <div class="flow-line"></div>
      </div>
      
      <!-- 科技感边框8 - 脉冲边框 -->
      <div v-if="type === 'border-8'" class="border-pulse"></div>
      
      <!-- 科技感边框9 - 多层边框 -->
      <div v-if="type === 'border-9'" class="border-multi">
        <div class="border-layer layer-1"></div>
        <div class="border-layer layer-2"></div>
        <div class="border-layer layer-3"></div>
      </div>
      
      <!-- 科技感边框10 - 动态边框 -->
      <div v-if="type === 'border-10'" class="border-dynamic">
        <div class="dynamic-corner corner-tl"></div>
        <div class="dynamic-corner corner-tr"></div>
        <div class="dynamic-corner corner-bl"></div>
        <div class="dynamic-corner corner-br"></div>
      </div>
      
      <!-- 科技感边框11 - 标题边框 -->
      <div v-if="type === 'border-11'" class="border-title">
        <div class="title-bar">
          <span class="title-text">{{ props.title || '标题' }}</span>
        </div>
      </div>
      
      <!-- 科技感边框12 - 圆角边框 -->
      <div v-if="type === 'border-12'" class="border-rounded"></div>
      
      <!-- 科技感边框13 - 霓虹边框 -->
      <div v-if="type === 'border-13'" class="border-neon"></div>
      
      <!-- 科技感边框14 - 金属边框 -->
      <div v-if="type === 'border-14'" class="border-metal"></div>
      
      <!-- 科技感边框15 - 玻璃边框 -->
      <div v-if="type === 'border-15'" class="border-glass"></div>
      
      <!-- 科技感边框16 - 火焰边框 -->
      <div v-if="type === 'border-16'" class="border-flame"></div>
      
      <!-- 科技感边框17 - 闪电边框 -->
      <div v-if="type === 'border-17'" class="border-lightning"></div>
      
      <!-- 科技感边框18 - 星空边框 -->
      <div v-if="type === 'border-18'" class="border-starry"></div>
      
      <!-- 科技感边框19 - 波浪边框 -->
      <div v-if="type === 'border-19'" class="border-wave"></div>
      
      <!-- 科技感边框20 - 齿轮边框 -->
      <div v-if="type === 'border-20'" class="border-gear"></div>
      
      <!-- 科技感边框21 - 电路边框 -->
      <div v-if="type === 'border-21'" class="border-circuit"></div>
      
      <!-- 科技感边框22 - 钻石边框 -->
      <div v-if="type === 'border-22'" class="border-diamond"></div>
      
      <!-- 科技感边框23 - 彩虹边框 -->
      <div v-if="type === 'border-23'" class="border-rainbow"></div>
      
      <!-- 科技感边框24 - 全息边框 -->
      <div v-if="type === 'border-24'" class="border-hologram"></div>
      
      <!-- 所有边框的内容区域 -->
      <div class="border-content">
        <slot>{{ props.content || '边框内容' }}</slot>
      </div>
    </div>
    
    <!-- 装饰标题 -->
    <div v-else-if="type === 'decoration-title'" class="decoration-title" :style="titleStyle">
      <span class="title-text">{{ props.title }}</span>
      <span v-if="props.decorationType === 'line'" class="title-line" :style="{ background: props.decorationColor }"></span>
      <span v-else-if="props.decorationType === 'box'" class="title-box" :style="{ borderColor: props.decorationColor }"></span>
      <span v-else-if="props.decorationType === 'corner'" class="title-corner" :style="{ borderColor: props.decorationColor }"></span>
    </div>
    
    <!-- 粒子效果 -->
    <div v-else-if="type === 'decoration-particles'" class="particle-decoration">
      <canvas ref="particleCanvas" class="particle-canvas"></canvas>
      <div class="particle-content">
        <slot>{{ props.content || '粒子效果内容' }}</slot>
      </div>
    </div>
    
    <!-- 扫描线动画 -->
    <div v-else-if="type === 'decoration-scan'" class="scan-decoration">
      <div class="scan-line" :style="scanLineStyle"></div>
      <div class="scan-content">
        <slot>{{ props.content || '扫描线内容' }}</slot>
      </div>
    </div>
    
    <!-- 光效 -->
    <div v-else-if="type === 'decoration-light'" class="light-decoration" :style="lightStyle">
      <div class="light-content">
        <slot>{{ props.content || '光效内容' }}</slot>
      </div>
    </div>
    
    <!-- 六边形装饰 -->
    <div v-else-if="type === 'decoration-hexagon'" class="hexagon-decoration">
      <div class="hexagon-shape"></div>
      <div class="hexagon-content">
        <slot>{{ props.content || '六边形内容' }}</slot>
      </div>
    </div>
    
    <!-- 圆形装饰 -->
    <div v-else-if="type === 'decoration-circle'" class="circle-decoration">
      <div class="circle-shape"></div>
      <div class="circle-content">
        <slot>{{ props.content || '圆形内容' }}</slot>
      </div>
    </div>
    
    <!-- 三角形装饰 -->
    <div v-else-if="type === 'decoration-triangle'" class="triangle-decoration">
      <div class="triangle-shape"></div>
      <div class="triangle-content">
        <slot>{{ props.content || '三角形内容' }}</slot>
      </div>
    </div>
    
    <!-- 虚线动画装饰 -->
    <div v-else-if="type === 'decoration-dashed'" class="dashed-decoration">
      <div class="dashed-border"></div>
      <div class="dashed-content">
        <slot>{{ props.content || '虚线动画内容' }}</slot>
      </div>
    </div>
    
    <!-- 路径动画装饰 -->
    <div v-else-if="type === 'decoration-path'" class="path-decoration">
      <svg class="path-svg" viewBox="0 0 100 100">
        <path class="path-animation" d="M10,50 Q25,25 50,50 T90,50" fill="none" stroke="#03d2d4" stroke-width="2"/>
      </svg>
      <div class="path-content">
        <slot>{{ props.content || '路径动画内容' }}</slot>
      </div>
    </div>
    
    <!-- 波浪线装饰 -->
    <div v-else-if="type === 'decoration-wave'" class="wave-decoration">
      <div class="wave-line"></div>
      <div class="wave-content">
        <slot>{{ props.content || '波浪线内容' }}</slot>
      </div>
    </div>
    
    <!-- 其他装饰类型可继续扩展 -->
  </div>
</template>

<script setup>
import { ref, onMounted, computed } from 'vue'

const props = defineProps({
  type: {
    type: String,
    required: true
  },
  props: {
    type: Object,
    default: () => ({})
  }
})

// 边框样式
const borderStyle = computed(() => {
  const baseStyle = {
    width: '100%',
    height: '100%',
    position: 'relative',
    background: props.props.backgroundColor || 'transparent'
  }
  
  // 根据不同类型设置不同的基础样式
  if (props.type === 'border-1') {
    return {
      ...baseStyle,
      border: '1px solid transparent'
    }
  } else if (props.type === 'border-2') {
    return {
      ...baseStyle,
      border: '1px solid transparent'
    }
  } else if (props.type === 'border-3') {
    return {
      ...baseStyle,
      border: '1px solid transparent'
    }
  } else if (props.type === 'border-4') {
    return {
      ...baseStyle,
      border: '1px solid transparent'
    }
  } else if (props.type === 'border-5') {
    return {
      ...baseStyle,
      border: '1px solid transparent'
    }
  } else if (props.type === 'border-6') {
    return {
      ...baseStyle,
      border: '1px solid transparent'
    }
  } else if (props.type === 'border-7') {
    return {
      ...baseStyle,
      border: '1px solid transparent'
    }
  } else if (props.type === 'border-8') {
    return {
      ...baseStyle,
      border: '1px solid transparent'
    }
  } else if (props.type === 'border-9') {
    return {
      ...baseStyle,
      border: '1px solid transparent'
    }
  } else if (props.type === 'border-10') {
    return {
      ...baseStyle,
      border: '1px solid transparent'
    }
  } else if (props.type === 'border-11') {
    return {
      ...baseStyle,
      border: '1px solid transparent'
    }
  } else if (props.type === 'border-12') {
    return {
      ...baseStyle,
      border: '1px solid transparent',
      borderRadius: '8px'
    }
  } else if (props.type === 'border-13') {
    return {
      ...baseStyle,
      border: '1px solid transparent'
    }
  } else if (props.type === 'border-14') {
    return {
      ...baseStyle,
      border: '1px solid transparent'
    }
  } else if (props.type === 'border-15') {
    return {
      ...baseStyle,
      border: '1px solid transparent'
    }
  } else if (props.type === 'border-16') {
    return {
      ...baseStyle,
      border: '1px solid transparent'
    }
  } else if (props.type === 'border-17') {
    return {
      ...baseStyle,
      border: '1px solid transparent'
    }
  } else if (props.type === 'border-18') {
    return {
      ...baseStyle,
      border: '1px solid transparent'
    }
  } else if (props.type === 'border-19') {
    return {
      ...baseStyle,
      border: '1px solid transparent'
    }
  } else if (props.type === 'border-20') {
    return {
      ...baseStyle,
      border: '1px solid transparent'
    }
  } else if (props.type === 'border-21') {
    return {
      ...baseStyle,
      border: '1px solid transparent'
    }
  } else if (props.type === 'border-22') {
    return {
      ...baseStyle,
      border: '1px solid transparent'
    }
  } else if (props.type === 'border-23') {
    return {
      ...baseStyle,
      border: '1px solid transparent'
    }
  } else if (props.type === 'border-24') {
    return {
      ...baseStyle,
      border: '1px solid transparent'
    }
  }
  
  // 默认样式
  return {
    ...baseStyle,
    border: `${props.props.borderWidth || '2px'} ${props.props.borderStyle || 'solid'} ${props.props.borderColor || '#03d2d4'}`,
    borderRadius: props.props.borderRadius || '8px',
    boxShadow: props.props.boxShadow || '0 0 8px #03d2d4'
  }
})

// 边框类名
const borderClass = computed(() => {
  return `border-type-${props.type.replace('border-', '')}`
})

// 标题样式
const titleStyle = computed(() => ({
  color: props.props.titleColor || '#03d2d4',
  fontSize: props.props.fontSize || '24px',
  fontWeight: 'bold',
  position: 'relative',
  padding: '8px 24px',
  display: 'inline-block'
}))

// 扫描线样式
const scanLineStyle = computed(() => ({
  background: props.props.scanColor || '#03d2d4',
  width: props.props.scanDirection === 'vertical' ? '4px' : '100%',
  height: props.props.scanDirection === 'vertical' ? '100%' : (props.props.scanWidth || '2px'),
  animation: `scan-move ${props.props.scanDuration || '3s'} linear infinite`,
  position: 'absolute',
  left: 0,
  top: 0
}))

// 光效样式
const lightStyle = computed(() => ({
  width: '100%',
  height: '100%',
  position: 'relative'
}))

// 粒子动画（简单占位）
const particleCanvas = ref(null)
onMounted(() => {
  if (props.type === 'decoration-particles' && particleCanvas.value) {
    const ctx = particleCanvas.value.getContext('2d')
    const w = particleCanvas.value.width = 200
    const h = particleCanvas.value.height = 100
    ctx.clearRect(0, 0, w, h)
    for (let i = 0; i < (props.props.particleNumber || 30); i++) {
      ctx.beginPath()
      ctx.arc(Math.random() * w, Math.random() * h, props.props.particleSize || 2, 0, 2 * Math.PI)
      ctx.fillStyle = props.props.particleColor || '#03d2d4'
      ctx.fill()
    }
  }
})
</script>

<style scoped>
.decoration-component {
  width: 100%;
  height: 100%;
  position: relative;
}

.border-decoration {
  box-sizing: border-box;
  width: 100%;
  height: 100%;
}

.border-content {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 16px;
  z-index: 2;
  position: relative;
}

/* 边框1 - 四角装饰 */
.border-corners {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  pointer-events: none;
}

.corner {
  position: absolute;
  width: 20px;
  height: 20px;
  border: 2px solid #03d2d4;
}

.corner-tl {
  top: 10px;
  left: 10px;
  border-right: none;
  border-bottom: none;
}

.corner-tr {
  top: 10px;
  right: 10px;
  border-left: none;
  border-bottom: none;
}

.corner-bl {
  bottom: 10px;
  left: 10px;
  border-right: none;
  border-top: none;
}

.corner-br {
  bottom: 10px;
  right: 10px;
  border-left: none;
  border-top: none;
}

/* 边框2 - 发光边框 */
.border-glow {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  border: 1px solid #03d2d4;
  box-shadow: 0 0 10px #03d2d4, inset 0 0 10px rgba(3, 210, 212, 0.1);
  animation: glow 2s ease-in-out infinite alternate;
}

@keyframes glow {
  from { box-shadow: 0 0 10px #03d2d4, inset 0 0 10px rgba(3, 210, 212, 0.1); }
  to { box-shadow: 0 0 20px #03d2d4, inset 0 0 20px rgba(3, 210, 212, 0.2); }
}

/* 边框3 - 扫描线边框 */
.border-scan {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  border: 1px solid #03d2d4;
  overflow: hidden;
}

.scan-border-line {
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 2px;
  background: linear-gradient(90deg, transparent, #03d2d4, transparent);
  animation: scan-border 3s linear infinite;
}

@keyframes scan-border {
  0% { left: -100%; }
  100% { left: 100%; }
}

/* 边框4 - 渐变边框 */
.border-gradient {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  border: 1px solid transparent;
  background: linear-gradient(45deg, #03d2d4, #00ffff, #03d2d4);
  background-size: 200% 200%;
  animation: gradient-shift 3s ease infinite;
}

@keyframes gradient-shift {
  0% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}

/* 边框5 - 虚线边框 */
.border-dashed {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  border: 2px dashed #03d2d4;
  animation: dash-move 20s linear infinite;
}

@keyframes dash-move {
  to { background-position: 100% 0; }
}

/* 边框6 - 立体边框 */
.border-3d {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  border: 2px solid #03d2d4;
  box-shadow: 
    inset 2px 2px 4px rgba(3, 210, 212, 0.3),
    inset -2px -2px 4px rgba(0, 0, 0, 0.3),
    0 0 10px rgba(3, 210, 212, 0.5);
}

/* 边框7 - 流光边框 */
.border-flow {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  border: 1px solid #03d2d4;
  overflow: hidden;
}

.flow-line {
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(3, 210, 212, 0.3), transparent);
  animation: flow 4s linear infinite;
}

@keyframes flow {
  0% { left: -100%; }
  100% { left: 100%; }
}

/* 边框8 - 脉冲边框 */
.border-pulse {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  border: 2px solid #03d2d4;
  animation: pulse-border 2s ease-in-out infinite;
}

@keyframes pulse-border {
  0%, 100% { 
    box-shadow: 0 0 5px #03d2d4;
    transform: scale(1);
  }
  50% { 
    box-shadow: 0 0 20px #03d2d4;
    transform: scale(1.02);
  }
}

/* 边框9 - 多层边框 */
.border-multi {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
}

.border-layer {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  border: 1px solid #03d2d4;
  animation: multi-pulse 3s ease-in-out infinite;
}

.layer-1 {
  animation-delay: 0s;
}

.layer-2 {
  animation-delay: 1s;
  border-color: #00ffff;
}

.layer-3 {
  animation-delay: 2s;
  border-color: #0080ff;
}

@keyframes multi-pulse {
  0%, 100% { 
    opacity: 0.3;
    transform: scale(1);
  }
  50% { 
    opacity: 1;
    transform: scale(1.05);
  }
}

/* 边框10 - 动态边框 */
.border-dynamic {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
}

.dynamic-corner {
  position: absolute;
  width: 30px;
  height: 30px;
  border: 2px solid #03d2d4;
  animation: dynamic-rotate 4s linear infinite;
}

.dynamic-corner.corner-tl {
  top: 10px;
  left: 10px;
  border-right: none;
  border-bottom: none;
}

.dynamic-corner.corner-tr {
  top: 10px;
  right: 10px;
  border-left: none;
  border-bottom: none;
  animation-delay: 1s;
}

.dynamic-corner.corner-bl {
  bottom: 10px;
  left: 10px;
  border-right: none;
  border-top: none;
  animation-delay: 2s;
}

.dynamic-corner.corner-br {
  bottom: 10px;
  right: 10px;
  border-left: none;
  border-top: none;
  animation-delay: 3s;
}

@keyframes dynamic-rotate {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

/* 边框11 - 标题边框 */
.border-title {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  border: 1px solid #03d2d4;
}

.title-bar {
  position: absolute;
  top: -15px;
  left: 20px;
  background: #0a1527;
  padding: 0 15px;
  height: 30px;
  display: flex;
  align-items: center;
  border: 1px solid #03d2d4;
  border-bottom: none;
}

.title-text {
  color: #03d2d4;
  font-size: 14px;
  font-weight: bold;
}

/* 边框12 - 圆角边框 */
.border-rounded {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  border: 2px solid #03d2d4;
  border-radius: 15px;
  box-shadow: 0 0 15px rgba(3, 210, 212, 0.5);
}

/* 装饰标题样式 */
.decoration-title {
  display: flex;
  align-items: center;
  gap: 8px;
  position: relative;
}

.title-text {
  z-index: 2;
}

.title-line {
  display: inline-block;
  height: 2px;
  width: 40px;
  margin-left: 8px;
}

.title-box {
  display: inline-block;
  border: 2px solid;
  width: 24px;
  height: 24px;
  margin-left: 8px;
}

.title-corner {
  display: inline-block;
  border: 2px solid;
  width: 16px;
  height: 16px;
  margin-left: 8px;
  border-radius: 4px;
}

.particle-canvas {
  width: 100%;
  height: 100%;
  background: transparent;
  display: block;
}

.scan-decoration {
  width: 100%;
  height: 100%;
  position: relative;
  overflow: hidden;
}

.scan-line {
  position: absolute;
  left: 0;
  top: 0;
  z-index: 1;
}

.scan-content {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 16px;
  z-index: 2;
  position: relative;
}

@keyframes scan-move {
  0% { transform: translateX(0); }
  100% { transform: translateX(100%); }
}

.light-decoration {
  position: relative;
  width: 100%;
  height: 100%;
}

.light-content {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 16px;
  z-index: 2;
  position: relative;
}

/* 添加光效动画 */
.light-decoration::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 20px;
  height: 20px;
  background: #03d2d4;
  border-radius: 50%;
  transform: translate(-50%, -50%);
  animation: light-pulse 2s ease-in-out infinite;
  z-index: 1;
  pointer-events: none;
}

@keyframes light-pulse {
  0%, 100% { 
    box-shadow: 0 0 0 0 rgba(3, 210, 212, 0.7);
    transform: translate(-50%, -50%) scale(1);
  }
  50% { 
    box-shadow: 0 0 20px 10px rgba(3, 210, 212, 0.3);
    transform: translate(-50%, -50%) scale(1.2);
  }
}

/* 边框13 - 霓虹边框 */
.border-neon {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  border: 2px solid #ff00ff;
  box-shadow: 
    0 0 10px #ff00ff,
    0 0 20px #ff00ff,
    0 0 30px #ff00ff,
    inset 0 0 10px rgba(255, 0, 255, 0.3);
  animation: neon-flicker 2s ease-in-out infinite alternate;
}

@keyframes neon-flicker {
  0%, 100% { 
    box-shadow: 
      0 0 10px #ff00ff,
      0 0 20px #ff00ff,
      0 0 30px #ff00ff,
      inset 0 0 10px rgba(255, 0, 255, 0.3);
  }
  50% { 
    box-shadow: 
      0 0 5px #ff00ff,
      0 0 10px #ff00ff,
      0 0 15px #ff00ff,
      inset 0 0 5px rgba(255, 0, 255, 0.1);
  }
}

/* 边框14 - 金属边框 */
.border-metal {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  border: 3px solid transparent;
  background: linear-gradient(45deg, #c0c0c0, #e0e0e0, #a0a0a0, #d0d0d0);
  background-size: 400% 400%;
  animation: metal-shine 3s ease infinite;
}

@keyframes metal-shine {
  0% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}

/* 边框15 - 玻璃边框 */
.border-glass {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  border: 1px solid rgba(255, 255, 255, 0.3);
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(10px);
  box-shadow: 
    0 8px 32px rgba(0, 0, 0, 0.3),
    inset 0 1px 0 rgba(255, 255, 255, 0.2);
}

/* 边框16 - 火焰边框 */
.border-flame {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  border: 2px solid transparent;
  background: linear-gradient(45deg, #ff4500, #ff6347, #ff8c00, #ff4500);
  background-size: 200% 200%;
  animation: flame-flicker 1.5s ease-in-out infinite;
}

@keyframes flame-flicker {
  0%, 100% { 
    background-position: 0% 50%;
    box-shadow: 0 0 20px rgba(255, 69, 0, 0.8);
  }
  50% { 
    background-position: 100% 50%;
    box-shadow: 0 0 30px rgba(255, 69, 0, 1);
  }
}

/* 边框17 - 闪电边框 */
.border-lightning {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  border: 2px solid #ffff00;
  overflow: hidden;
}

.border-lightning::before {
  content: '';
  position: absolute;
  top: -100%;
  left: -100%;
  width: 300%;
  height: 300%;
  background: linear-gradient(45deg, transparent, #ffff00, transparent);
  animation: lightning-flash 2s ease-in-out infinite;
}

@keyframes lightning-flash {
  0%, 90%, 100% { opacity: 0; transform: translate(-100%, -100%) rotate(45deg); }
  10%, 80% { opacity: 1; transform: translate(0%, 0%) rotate(45deg); }
}

/* 边框18 - 星空边框 */
.border-starry {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  border: 1px solid #87ceeb;
  background: radial-gradient(circle at 20% 20%, rgba(135, 206, 235, 0.3) 0%, transparent 50%),
              radial-gradient(circle at 80% 80%, rgba(255, 255, 255, 0.3) 0%, transparent 50%);
  animation: starry-twinkle 4s ease-in-out infinite;
}

@keyframes starry-twinkle {
  0%, 100% { opacity: 0.7; }
  50% { opacity: 1; }
}

/* 边框19 - 波浪边框 */
.border-wave {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  border: 2px solid #4169e1;
  overflow: hidden;
}

.border-wave::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 200%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(65, 105, 225, 0.5), transparent);
  animation: wave-move 3s linear infinite;
}

@keyframes wave-move {
  0% { left: -100%; }
  100% { left: 100%; }
}

/* 边框20 - 齿轮边框 */
.border-gear {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  border: 2px solid #696969;
  background: repeating-conic-gradient(
    from 0deg,
    #696969 0deg 10deg,
    transparent 10deg 20deg
  );
  animation: gear-rotate 4s linear infinite;
}

@keyframes gear-rotate {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

/* 边框21 - 电路边框 */
.border-circuit {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  border: 1px solid #00ff00;
  background: 
    linear-gradient(90deg, transparent 49%, #00ff00 49%, #00ff00 51%, transparent 51%),
    linear-gradient(0deg, transparent 49%, #00ff00 49%, #00ff00 51%, transparent 51%);
  background-size: 20px 20px;
  animation: circuit-pulse 2s ease-in-out infinite;
}

@keyframes circuit-pulse {
  0%, 100% { opacity: 0.5; }
  50% { opacity: 1; }
}

/* 边框22 - 钻石边框 */
.border-diamond {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  border: 2px solid #b9f2ff;
  background: linear-gradient(45deg, #b9f2ff, #ffffff, #b9f2ff);
  background-size: 200% 200%;
  animation: diamond-sparkle 3s ease infinite;
  clip-path: polygon(10% 0%, 90% 0%, 100% 10%, 100% 90%, 90% 100%, 10% 100%, 0% 90%, 0% 10%);
}

@keyframes diamond-sparkle {
  0% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}

/* 边框23 - 彩虹边框 */
.border-rainbow {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  border: 3px solid transparent;
  background: linear-gradient(45deg, 
    #ff0000, #ff7f00, #ffff00, #00ff00, #0000ff, #4b0082, #9400d3);
  background-size: 400% 400%;
  animation: rainbow-shift 4s ease infinite;
}

@keyframes rainbow-shift {
  0% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}

/* 边框24 - 全息边框 */
.border-hologram {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  border: 2px solid transparent;
  background: linear-gradient(45deg, 
    rgba(255, 0, 255, 0.8), 
    rgba(0, 255, 255, 0.8), 
    rgba(255, 255, 0, 0.8), 
    rgba(255, 0, 255, 0.8));
  background-size: 400% 400%;
  animation: hologram-shift 3s ease infinite;
}

@keyframes hologram-shift {
  0% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}

/* 粒子装饰 */
.particle-decoration {
  width: 100%;
  height: 100%;
  position: relative;
}

.particle-canvas {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 1;
  pointer-events: none;
}

.particle-content {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 16px;
  z-index: 2;
  position: relative;
}

/* 六边形装饰 */
.hexagon-decoration {
  width: 100%;
  height: 100%;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}

.hexagon-shape {
  position: absolute;
  width: 80%;
  height: 80%;
  background: linear-gradient(45deg, #03d2d4, #00ffff);
  clip-path: polygon(50% 0%, 100% 25%, 100% 75%, 50% 100%, 0% 75%, 0% 25%);
  animation: hexagon-rotate 4s linear infinite;
  z-index: 1;
}

.hexagon-content {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 16px;
  z-index: 2;
  position: relative;
}

@keyframes hexagon-rotate {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

/* 圆形装饰 */
.circle-decoration {
  width: 100%;
  height: 100%;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}

.circle-shape {
  position: absolute;
  width: 80%;
  height: 80%;
  border: 3px solid #03d2d4;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(3, 210, 212, 0.1) 0%, transparent 70%);
  animation: circle-pulse 2s ease-in-out infinite;
  z-index: 1;
}

.circle-content {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 16px;
  z-index: 2;
  position: relative;
}

@keyframes circle-pulse {
  0%, 100% { 
    transform: scale(1);
    box-shadow: 0 0 10px rgba(3, 210, 212, 0.5);
  }
  50% { 
    transform: scale(1.05);
    box-shadow: 0 0 20px rgba(3, 210, 212, 0.8);
  }
}

/* 三角形装饰 */
.triangle-decoration {
  width: 100%;
  height: 100%;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}

.triangle-shape {
  position: absolute;
  width: 0;
  height: 0;
  border-left: 40px solid transparent;
  border-right: 40px solid transparent;
  border-bottom: 70px solid #03d2d4;
  animation: triangle-bounce 2s ease-in-out infinite;
  z-index: 1;
}

.triangle-content {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 16px;
  z-index: 2;
  position: relative;
}

@keyframes triangle-bounce {
  0%, 100% { transform: translateY(0px); }
  50% { transform: translateY(-10px); }
}

/* 虚线动画装饰 */
.dashed-decoration {
  width: 100%;
  height: 100%;
  position: relative;
}

.dashed-border {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  border: 2px dashed #03d2d4;
  animation: dashed-move 20s linear infinite;
  z-index: 1;
}

.dashed-content {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 16px;
  z-index: 2;
  position: relative;
}

@keyframes dashed-move {
  0% { background-position: 0 0; }
  100% { background-position: 100% 100%; }
}

/* 路径动画装饰 */
.path-decoration {
  width: 100%;
  height: 100%;
  position: relative;
}

.path-svg {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 1;
  pointer-events: none;
}

.path-animation {
  stroke-dasharray: 100;
  stroke-dashoffset: 100;
  animation: path-draw 3s ease-in-out infinite;
}

.path-content {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 16px;
  z-index: 2;
  position: relative;
}

@keyframes path-draw {
  0% { stroke-dashoffset: 100; }
  50% { stroke-dashoffset: 0; }
  100% { stroke-dashoffset: -100; }
}

/* 波浪线装饰 */
.wave-decoration {
  width: 100%;
  height: 100%;
  position: relative;
}

.wave-line {
  position: absolute;
  top: 50%;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, transparent, #03d2d4, transparent);
  transform: translateY(-50%);
  animation: wave-flow 2s ease-in-out infinite;
  z-index: 1;
}

.wave-content {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 16px;
  z-index: 2;
  position: relative;
}

@keyframes wave-flow {
  0%, 100% { 
    transform: translateY(-50%) scaleX(1);
    opacity: 0.5;
  }
  50% { 
    transform: translateY(-50%) scaleX(1.2);
    opacity: 1;
  }
}
</style> 